﻿namespace Arms.Application.Modules.Security
{
    using Arms.Application.Services;
    using Arms.Framework.Security;

    /// <summary>
    /// Base contract for serice that handles user authentication and data.
    /// </summary>
    public interface IMembershipService : IServiceBase
    {
        /// <summary>
        /// Retrieve ArmsUserData by resolving the user
        /// </summary>
        /// <param name="user"></param>
        /// <returns></returns>
        ArmsUserData GetArmsUserData(MembershipAuthenticationResult result);
        /// <summary>
        /// Determines whether username + password matches database.
        /// </summary>
        /// <param name="userName"></param>
        /// <param name="password"></param>
        /// <returns></returns>
        MembershipAuthenticationResult Authenticate(string userName, string password);
        /// <summary>
        /// Determines whether employee number matches database.
        /// </summary>
        /// <param name="employeeNumber"></param>
        /// <returns></returns>
        MembershipAuthenticationResult Authenticate(long employeeNumber);
    }
}
